package com.shuyu.domain;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;

import java.io.Serializable;
import java.util.Date;

@Data
@ApiModel(description = "授权审批")
@TableName("tbl_approval_authorize")
public class ApprovalAuthorize implements Serializable {
    private static final long serialVersionUID = -8366784583130089874L;
    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;
    @ApiModelProperty(value = "用户ID")
    private Long userId;
    @ApiModelProperty(value = "用户名")
    private transient String userName;
    @ApiModelProperty(value = "审批授权给与用户id")
    private Long authorizeUserId;
    @ApiModelProperty(value = "审批授权给与用户名")
    private transient String authorizeUserName;
    @ApiModelProperty(value = "授权结束时间")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date authorizeEndTime;
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date createTime;
    private Date modifyTime;
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @ApiModelProperty(value = "取消授权结束时间")
    private Date cancelTime;
    @ApiModelProperty(value = "授权状态 0正常 1取消")
    private Integer status;
    @ApiModelProperty(value = "授权原因")
    private String authorizeReason;
    @ApiModelProperty(value = "授权类型 0全部 1产品 2活动")
    private Integer authorizeType;
}
